Welcome Guest | Sign in | Register
Advanced Java - Java Programming Interview Questions and Answers | LucentBlackBoard | LucentBlackBoard.com

Home > Technical Interviews > Computer Science & Engineering > Java Programming > Advanced Java Questions and Answers

111. What is the difference between static and non-static variables?

A static variable is associated with the class as a whole rather than with specific instances of a class.

Non-static variables take on unique values with each object instance.

112. What is the difference between the paint() and repaint() methods?

The paint() method supports painting via a Graphics object. The repaint() method is used to causepaint() to be invoked by the AWT painting thread.

113. What is the purpose of the File class?

The File class is used to create objects that provide access to the files and directories of a local file system.

114. Can an exception be rethrown?

Yes, an exception can be rethrown.

115. Which Math method is used to calculate the absolute value of a number?

The abs() method is used to calculate absolute values.




Partner Sites
LucentBlackBoard.com                  SoftLucent.com                  LucentJobs.com
All rights reserved © 2012-2015 SoftLucent.